package com.hsj.busmanager.service;

import com.hsj.busmanager.api.Cost;
import com.hsj.busmanager.api.Rent;
import com.hsj.busmanager.mapper.CostMapper;
import com.hsj.busmanager.mapper.RentMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class OtherCostService {

    @Autowired
    private CostMapper costMapper;


    public void updateIsPay(Integer id) {

        Cost cost = new Cost();
        cost.setId(id);
        cost.setIsPay(1);
        costMapper.updateByPrimaryKeySelective(cost);

    }

    public void insert(Cost cost) {
        costMapper.insert(cost);
    }
}
